import sortingRoutes from "./sorting";
import cooperateRoutes from "./cooperate";
import governmentRoutes from "./government";

const commonRoute = [
	{
		path: "/",
		name: "home",
		component: () => import("@/pages/home/index.vue"),
		meta: {
			keepAlive: false,
			title: "首页",
			breadcrumb: [
				{
					title: "首页",
					path: "/"
				},
			],
			openMenu: '0'
		}
	},
	{
		path: "/common/notificationManage",
		name: "notificationManage",
		component: () => import("@/pages/common/notificationManage/index.vue"),
		meta: {
			keepAlive: false,
			title: "消息中心",
			breadcrumb: [
				{
					title: "首页",
					path: "/"
				},
				{
					title: "消息中心",
					path: "/notificationManage"
				},
			],
		}
	},
];

const childrenRoute = commonRoute.concat(sortingRoutes).concat(governmentRoutes).concat(cooperateRoutes);

const baseRoute = [
	{
		path: "/",
		name: "",
		component: () => import("@/pages/index/index.vue"),
		meta: {keepAlive: false, type: 0},
		children: childrenRoute
	},
	{
		path: "/login",
		name: "login",
		component: () => import("@/pages/login/login.vue"),
		meta: {keepAlive: false}
	},
	{
		path: "*",
		name: "notfount",
		component: () => import("@/pages/error/error.vue"),
		meta: {keepAlive: false}
	}
];

export default baseRoute;
